Return error when flushing without pixel format#808
Open
hjanuschka wants to merge 1 commit into
Open
Conversation
Member
|
I'm not sure this is the correct fix - this sounds like an API usage error on the Chrome side. How hard is it to stop Chrome from calling flush_pixels before pixel format is set? (i.e. before image info is available) |
Collaborator
Author
|
https://chromium-review.googlesource.com/c/chromium/src/+/7965920 feel free to close, if having it as a additional defensive guard in the lib or not |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Chromium's blink_jxl_decoder_fuzzer found that
flush_pixelscan be reached before the inner decoder has reached the point where the output pixel format is set. That path panicked atpixel_format.unwrap()instead of returning a decoder error.Return a normal
PixelFormatNotSeterror instead, which callers can already handle as decode failure. The regression test coversflush_pixelsbefore pixel format setup.https://issues.chromium.org/issues/526010666